package com.eliota.mapper;

import com.eliota.entity.Role;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.apache.ibatis.annotations.Delete;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Select;

/**
 * <p>
 *  Mapper 接口
 * </p>
 *
 * @author MG
 * @since 2023-03-28
 */
@Mapper
public interface RoleMapper extends BaseMapper<Role> {


    @Delete("delete from t_role where t_role.id = #{id}")
    int deleteById(Integer id);

    @Select("select t_role.id from t_role where t_role.flag = #{flag}")
    Integer selectByFlag(String flag);
}
